﻿using System;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;

//  2008 by Mario Meir-Huber
// Mail: mario_mh@vb-magazin.de
//       i-mameir@microsoft.com
namespace ChartLibrary.Data
{
    /// <summary>
    /// This class stores one single Chart Data object
    /// </summary>
    /// <history>
    ///     03/15/08: Design and Implementation for 0.1
    /// </history>
    public class ChartData
    {
        private double _value = 0.0;               //value 
        private string _xaxisvalue = string.Empty; //x axis value
        private object _tag = null;                //tag

        /// <summary>
        /// Initializes the class
        /// </summary>
        public ChartData()
        {

        }

        /// <summary>
        /// Initializes the class
        /// </summary>
        /// <param name="value">Value of the Item</param>
        public ChartData(double value)
        {
            _value = value;
        }

        /// <summary>
        /// Initializes the class
        /// </summary>
        /// <param name="value">Value of the Item</param>
        /// <param name="xaxisvalue">Value for the X Axis</param>
        public ChartData(double value, string xaxisvalue) : this(value)
        {
            _xaxisvalue = xaxisvalue;
        }

        /// <summary>
        /// Initializes the class
        /// </summary>
        /// <param name="value">Value of the Item</param>
        /// <param name="xaxisvalue">Value for the X Axis</param>
        /// <param name="tag">Object storage for the class</param>
        public ChartData(double value, string xaxisvalue, object tag)
            : this(value, xaxisvalue)
        {
            _tag = tag;
        }

        /// <summary>
        /// This gets the value or sets it
        /// </summary>
        public double Value 
        {
            get { return _value; }
            set { _value = value; }
        }

        /// <summary>
        /// This gets the X Axis Value or sets it
        /// </summary>
        public string XAxisValue 
        {
            get { return _xaxisvalue; }
            set { _xaxisvalue = value; }
        }

        /// <summary>
        /// This gets the Tag or sets it
        /// </summary>
        public object Tag 
        {
            get { return _tag; }
            set { _tag = value; } 
        }
    }
}
